/*------------------app.layout.less begin-----------------------*/
html, body{
    width: 100%;
    height: 100%;
}
body{
    overflow-x: hidden;
}

.app{
    height: auto;
    min-height: 100%;
    width: 100%;
    position: relative;
    &:before{
        content: "";
        position: absolute;
        width: inherit;
        top: 0;
        bottom: 0;
        z-index: -1;
        background-color: $body-bg;
        border: inherit;
        display: block;
    }
}
//header
.app-header-fixed{
    padding-top: $app-header-height;
    .app-header{
        position: fixed;
        top: 0;
        left:0;
        width: 100%;
    }
}

.app-header{
    z-index: 1025;
    border-radius: 0;
}

.navigationBox{
    height:$app-header-height;
    line-height:$app-header-height;
    p{
        font-size:14px;
        color:#666;
        text-align:left;
    }
    .collapse-icon{
        height:$app-header-height;
    }
}
// aside
/*.layout-box{
    width: 100%;
    float: left;
    &:before{
        content: "";
        position: absolute;
        width: inherit;
        top: 0;
        bottom: 0;
        left:0;
        z-index: -1;
        background-color: inherit;
        border: inherit;
    }
}*/
//left
.app-aside{
    position:absolute;
    top:0;
    left:0;
    height:100%!important;
}
//right
.container{
    width:100%;
    height:100%!important;
    position:absolute;
    padding-left:$app-aside-width;
    left:0;
    top: 0;
    padding-right:0;
}
.app-content{
    position: relative;
    padding:$app-header-height + $divi-h $divi-h $app-footer-height + $divi-h;
    height:100%;
}
//footer
.app-aside-footer{
    position: absolute;
    bottom: 0;
    width: 100%;
    z-index: 1000;
    max-width: $app-aside-width;
    .app-aside-folded & {
        max-width: $app-aside-folded-width;
    }
    ~ div{
        padding-bottom: 50px;
    }
}

.app-aside-right{
    padding-bottom: $app-header-height;
}

// content
.app-content-full{
    position: absolute;
    top: $app-header-height;
    bottom: $app-header-height;
    height: auto;
    width: auto !important;
    padding: 0 !important;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    &.h-full{
        bottom: 0;
        height: auto;
    }
}

.app-content-body{
    padding-bottom: $app-header-height;
    float: left;
    width: 100%;
}

// footer
.app-footer{
    height:$app-footer-height;
    line-height:$app-footer-height;
    border:1px solid $outline-line;
    background-color:$normal;
    padding-left:10px;
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1005;
    &.app-footer-fixed{
        position: fixed;
        margin-left: $app-aside-width;
    }
}

.hbox{
    display: table;
    table-layout: fixed;
    border-spacing: 0;
    width: 100%;
    height: 100%;
    .col{
        display: table-cell;
        vertical-align: top;
        height: 100%;
        float: none;
    }
}

.v-middle{vertical-align: middle !important;}
.v-top{vertical-align: top !important;}
.v-bottom{vertical-align: bottom !important;}

.vbox{
    display: table;
    border-spacing:0;
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 240px;
    .row-row {
        display: table-row;
        height: 100%;
        .cell {
            position: relative;
            height: 100%;
            width: 100%;
            -webkit-overflow-scrolling:touch;
            overflow: auto;
            .ie & {
                display: table-cell;
            }
            .cell-inner {
                position: absolute;
                top: 0;
                bottom: 0;
                left: 0;
                right: 0;
            }
        }
    }
}

// navbar
.navbar{
    .navbar-form-sm{
        margin-top: 10px;
        margin-bottom: 10px;
    }
    border-width: 0;
    border-radius: 0;
    margin: 0;
}

.navbar-md{
    min-height: $app-header-md-height;
    .navbar-btn{
        margin-top: 13px;
    }
    .navbar-form{
        margin-top: 15px;
    }
    .navbar-nav > li > a{
        padding-top: 20px;
        padding-bottom: 20px;
    }
    .navbar-brand{
        line-height: 60px;
    }
}

.navbar-header{
    > button{
        text-decoration: none;
        line-height: 30px;
        font-size: 16px;
        padding: 10px 17px;
        border: none;
        background-color: transparent;
    }
}

.navbar-brand{
    float: none;
    text-align: center;
    font-size: 12px;
    font-weight: bold;
    color:#fff;
    height: auto;
    line-height: $app-header-height;
    display: inline-block;
    padding: 0 16px;
    width: 100%;
    &:hover{
        text-decoration: none;
    }
    .logo{
        background:url("../images/logo.png") no-repeat left center;background-size: auto 38px;
        width:32px;height:50px;float: left;
    }
    span{
        float: left;
        color: #fff;
    }
}
@media (min-width: 768px) {
    .main-layout .app-grid{
        margin-left:$app-tree-width+$divi-h;
    }
    .app-aside,
    .navbar-header {
        width: $app-aside-width;
        height:$app-header-height;
    }
    .navbar-collapse{
        margin-left: $app-aside-width;
    }
    .app-aside-right{
        position: absolute;
        top: $app-header-height;
        bottom: 0;
        right: 0;
        z-index: 1000;
        &.pos-fix{
            z-index: 1010;
        }
    }

    .visible-folded{display: none;}

    .app-aside-folded{
        .hidden-folded{
            display: none !important;
        }
        .visible-folded{
            display: inherit;
        }
        .text-center-folded{
            text-align: center;
        }
        .pull-none-folded{
            float: none !important;
        }
        .w-auto-folded{
            width: auto;
        }

        .app-aside,
        .navbar-header {
            width: $app-aside-folded-width;
            padding-left:15px;
        }
        .navbar-collapse,
        .app-footer{
            margin-left: $app-aside-folded-width;
        }
        .container{
            padding-left:$app-aside-folded-width;
        }
        .app-header{
            .navbar-brand{
                display: block;
                padding: 0;
            }
        }
        .layout-wrap{
            left: $app-aside-folded-width;
        }

    }

    .app-aside-fixed{
        .app-header{
            .navbar-header{
                position: fixed;
            }
        }
        .aside-wrap{
            position: fixed;
            overflow: hidden;
            top: 0;
            bottom: 0;
            left: 0;
            width: $app-aside-width;
            z-index: 1000;
            .navi-wrap{
                width: $app-aside-width + $scroll-bar-width;
                padding-top:$divi-h;
                position: relative;
                height: 100%;
                overflow-x:hidden;
                overflow-y: scroll;
                -webkit-overflow-scrolling: touch;
                &::-webkit-scrollbar {
                    -webkit-appearance: none;
                }
                &::-webkit-scrollbar:vertical {
                    width: $scroll-bar-width;
                }
            }
            .smart & .navi-wrap{
                width: $app-aside-width;
            }
        }

        &.app-aside-folded{
            .app-aside{
                position: fixed;
                top: 0;
                bottom: 0;
                z-index: 1010;
            }
            .aside-wrap{
                width: $app-aside-folded-width;
                .navi-wrap{
                    width: $app-aside-folded-width + $scroll-bar-width;
                }
                .smart & .navi-wrap{
                    width: $app-aside-folded-width;
                }
            }
        }
    }

    .bg-auto{
        &:before{
            content: "";
            position: absolute;
            width: inherit;
            top: 0;
            bottom: 0;
            z-index: -1;
            background-color: inherit;
            border: inherit;
        }
        &.b-l:before{
            margin-left: -1px;
        }
        &.b-r:before{
            margin-right: -1px;
        }
    }

    .col.show{
        display: table-cell !important;
    }
}

// sm
@media (min-width: 768px) and (max-width: 991px) {
    .hbox-auto-sm{
        display: block;
        > .col{
            width: auto;
            height: auto;
            display: block;
            &.show{
                display: block !important;
            }
        }

    }
}
// xs
@media (max-width: 767px) {
    .app-aside{
        float: none;
    }
    .app-content-full{
        width: 100% !important;
    }
    .hbox-auto-xs{
        display: block;
        > .col{
            width: auto;
            height: auto;
            display: block;
        }
    }
    .navbar-nav{
        margin-top: 0;
        margin-bottom: 0;
        > li > a{
            box-shadow:0 -1px 0 rgba(0,0,0,0.1);
            .up{
                top: 0;
            }
            .avatar{
                width: 30px;
                margin-top: -5px;
            }
        }
        .open .dropdown-menu{
            background-color: #fff;
        }
    }
    .navbar-form{
        box-shadow:0 -1px 0 rgba(0,0,0,0.1);
        margin-top: 0 !important;
        margin-bottom: 0 !important;
        .form-group{
            margin-bottom: 0;
        }
    }
}


//tree
.layout-box{
    height:100%;
    padding:0;
}
.layout-box:nth-child(1){
    padding-right:5px;
}
.layout-box:nth-child(2){
    padding-left:5px;
}
.layout-content{
    //background-color:$normal;
    height:100%;
    //overflow: auto;
}
.tree-wrap .list-group td{
    width:100%;
}
.panel-heading .toolbtn{
    float:right;
    font-weight: normal;
    color:#333;
    i{
        margin-left:10px;
    }
}
.panel > .panel-body{
    padding:15px 20px;
    overflow: hidden!important;
    height:calc(100% - 40px);
    -webkit-height:calc(100% - 40px);
    -moz-height:calc(100% - 40px);
    width:100%;
    -webkit-user-select: none!important;
    -moz-user-select: none!important;
    -ms-user-select: none!important;
    user-select: none!important;
}
.panel.panel-default{
    border:1px solid $outline-line;
    height:100%!important;
}

.authorBox .panel > .panel-body{
    padding:0;
    overflow: hidden!important;
}
.authorBox .ui-grid{
    border:none!important;
}
.passwordArea .row{
    margin:0!important;
}
